package com.facebook.app.client.view;

import com.facebook.app.client.presenter.ReadyForClusteringPresenter;
import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.HasHorizontalAlignment;
import com.google.gwt.user.client.ui.Image;
import com.google.gwt.user.client.ui.VerticalPanel;
import com.google.gwt.user.client.ui.Widget;

public class ReadyForClusteringView extends Composite implements  ReadyForClusteringPresenter.Display {
	
	private final VerticalPanel statusPanel = new VerticalPanel();
	private final Image loadingImage = new Image("http://www.crewcheck.org/images/loading.gif");
	
	public ReadyForClusteringView() {
		initWidget(statusPanel);
		statusPanel.setSpacing(4);
		
		statusPanel.add(loadingImage);
		statusPanel.setCellHorizontalAlignment(loadingImage, HasHorizontalAlignment.ALIGN_CENTER);
	}
	
	@Override
	public Image getLoadingImage() {
		return loadingImage;
	}
	
	@Override
	public Widget asWidget() {
		return this;
	}

}
